import { defineStore } from 'pinia'
import { useStorage } from '@vueuse/core'


const useUserStore = defineStore('User', () => {
  // state
  const satoken = useStorage('satoken', '', localStorage)
  const userInfo = useStorage('userInfo', {}, localStorage)
  const peiduiImg = useStorage('peiduiImg', '', localStorage)
  // action

  // getter
  return {
    satoken,
    userInfo,
    peiduiImg
  }
})
export default useUserStore
